<script setup lang="ts">
import { ref, onMounted } from 'vue';

const currentYear = ref(new Date().getFullYear());
</script>

<template>
  <div class="app-wrapper">
    <main class="main-content">
      <router-view />
    </main>
    
    <footer class="site-footer">
      <div class="footer-content">
        <p>&copy; {{ currentYear }} TAO AI 智能助手 | 版权所有</p>
        <p class="footer-links">
          <a href="#">隐私政策</a> | 
          <a href="#">使用条款</a> | 
          <a href="#">关于我们</a>
        </p>
      </div>
    </footer>
  </div>
</template>

<style>
/* 全局样式 */
:root {
  --primary-color: #42b883;
  --primary-dark: #3aa876;
  --secondary-color: #2c3e50;
  --background-dark: #1a1a1a;
  --background-light: #f9f9f9;
  --text-light: rgba(255, 255, 255, 0.87);
  --text-dark: #213547;
  --border-radius: 8px;
  --transition-speed: 0.3s;
}

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  scroll-behavior: smooth;
}

#app {
  height: 100vh;
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.app-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.main-content {
  flex: 1;
}

/* 响应式设计 */
@media (max-width: 768px) {
  :root {
    --border-radius: 6px;
  }
}

@media (max-width: 480px) {
  :root {
    --border-radius: 4px;
  }
}
</style>

<style scoped>
.site-footer {
  background-color: var(--secondary-color);
  color: var(--text-light);
  padding: 1rem;
  text-align: center;
  font-size: 0.9rem;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-links {
  margin-top: 0.5rem;
}

.footer-links a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color var(--transition-speed);
}

.footer-links a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

@media (max-width: 480px) {
  .site-footer {
    padding: 0.8rem;
    font-size: 0.8rem;
  }
}
</style>

<style scoped>
.logo {
  height: 6em;
  padding: 1.5em;
  will-change: filter;
  transition: filter 300ms;
}
.logo:hover {
  filter: drop-shadow(0 0 2em #646cffaa);
}
.logo.vue:hover {
  filter: drop-shadow(0 0 2em #42b883aa);
}
</style>
